package com.itheima.edu.info.manager.day15;


import java.io.IOException;
import java.net.*;

public class UdpTest {
    public static void main(String[] args) throws IOException {
        DatagramSocket datagramSocket=new DatagramSocket();
        byte[] bytes = "998998".getBytes();
        InetAddress ip= InetAddress.getByName("127.0.0.1");
        DatagramPacket dp=new DatagramPacket(bytes,bytes.length,ip,20000);
        datagramSocket.send(dp);
        datagramSocket.close();
    }
}
